package com.ztgf.shopping.mapper.shop;

import com.baomidou.mybatisplus.plugins.Page;
import com.ztgf.shopping.models.bo.shop.ShopOperationBO;
import com.ztgf.shopping.models.vo.shop.*;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.math.BigDecimal;
import java.util.Date;
import java.util.List;

/*
 * @author: chenyu.wang
 * @date: 2020-08-19
 * @description:店铺运营映射
 */
@Mapper
public interface ShopOperationMapper {

    /*
     * @description:获取当前店铺待签收的订单数量和待收货款金额
     * @author: chenyu.wang
     * @date: 2020-08-19
     */
    ShopOperationOneVO queryShopSignedNum(@Param("shopId") Long shopId);

    /*
     * @description:获取店铺今日销售额
     * @author: chenyu.wang
     * @date: 2020-08-19
     */
    BigDecimal queryShopThisDaySales(@Param("item") ShopOperationBO bo);

    /*
     * @description:获取店铺本周销售额
     * @author: chenyu.wang
     * @date: 2020-08-19
     */
    List<ShopOperationVO> queryShopThisWeekSales(@Param("item") ShopOperationBO bo);

    /*
     * @description:获取店铺本月销售额
     * @author: chenyu.wang
     * @date: 2020-08-19
     */
    List<ShopOperationVO> queryShopMonthSales(@Param("item") ShopOperationBO bo);

    /*
     * @description:获取店铺自定义时间段的销售额统计
     * @author: chenyu.wang
     * @date: 2020-08-19
     */
    ShopOperationVO queryAutoTimeSales(@Param("item") ShopOperationBO bo);

    /*
     * @description:店铺运营订单量统计头部数据
     * @author: chenyu.wang
     * @date: 2020-08-20
     */
    ShopOperationTwoVO queryOrderHeader(@Param("shopId") Long shopId);

    /*
     * @description:店铺运营订单量统计今日订单数量
     * @author: chenyu.wang
     * @date: 2020-08-20
     */
    ShopOperationThreeVO queryShopOrderVolumeThisDay(@Param("item") ShopOperationBO bo);

    /*
     * @description:店铺运营本周订单量统计
     * @author: chenyu.wang
     * @date: 2020-08-20
     */
    List<ShopOperationThreeVO> queryShopOrderVolumeThisWeek(@Param("item") ShopOperationBO bo);

    /*
     * @description:店铺运营每月订单量统计
     * @author: chenyu.wang
     * @date: 2020-08-20
     */
    List<ShopOperationThreeVO> queryShopOrderVolumeThisMonth(@Param("item") ShopOperationBO bo);

    /*
     * @description:店铺运营自定义时间段的订单量统计
     * @author: chenyu.wang
     * @date: 2020-08-20
     */
    ShopOperationThreeVO queryShopOrderVolumeAutoTime(@Param("item") ShopOperationBO bo);

    /*
     * @description:今日新增订单列表
     * @author: chenyu.wang
     * @date: 2020-08-20
     */
    List<ShopOperationFourVO> queryShopOrderToDayList(Page<ShopOperationFourVO> page, Long shopId);

    /*
     * @description:订单商品
     * @author: chenyu.wang
     * @date: 2020-08-20
     */
    List<ShopOperationFiveVO> queryOrderInfoGoods(@Param("orderId") Long orderId);

    /*
     * @description:查询订单付款信息
     * @author: chenyu.wang
     * @date: 2020-08-20
     */
    List<ShopOperationSixVO> queryOrderInfoPayMsg(@Param("orderId") Long orderId);

    /*
     * @description:店铺运营pv/uv今日浏览量
     * @author: chenyu.wang
     * @date: 2020-08-20
     */
    ShopOperationSevenVO queryShopPageViewsToday(@Param("item") ShopOperationBO bo);

    /*
     * @description:店铺运营pv/uv本周浏览量
     * @author: chenyu.wang
     * @date: 2020-08-20
     */
    List<ShopOperationSevenVO> queryShopPageViewsThisWeek(@Param("item") ShopOperationBO bo);

    /*
     * @description:店铺运营pv/uv本月浏览量
     * @author: chenyu.wang
     * @date: 2020-08-20
     */
    List<ShopOperationSevenVO> queryShopPageViewsThisMonth(@Param("item") ShopOperationBO bo);

    /*
     * @description:店铺运营pv/uv自定义时间浏览量
     * @author: chenyu.wang
     * @date: 2020-08-20
     */
    ShopOperationSevenVO queryShopPageViewsAutoTime(@Param("item") ShopOperationBO bo);

    /*
     * @description:今日访客量
     * @author: chenyu.wang
     * @date: 2020-08-21
     */
    ShopOperationSevenVO queryShopVisitorsToday(@Param("item") ShopOperationBO bo);

    /*
     * @description:店铺运营pv/uv本周访客量
     * @author: chenyu.wang
     * @date: 2020-08-21
     */
    List<ShopOperationSevenVO> queryShopVisitorsThisWeek(@Param("item") ShopOperationBO bo);

    /*
     * @description:店铺运营pv/uv本月访客量
     * @author: chenyu.wang
     * @date: 2020-08-21
     */
    List<ShopOperationSevenVO> queryShopVisitorsThisMonth(@Param("item") ShopOperationBO bo);

    /*
     * @description:店铺运营pv/uv自定义时间访客量
     * @author: chenyu.wang
     * @date: 2020-08-21
     */
    ShopOperationSevenVO queryShopVisitorsAutoTime(@Param("item") ShopOperationBO bo);

    /*
     * @description:获取店铺昨日浏览量
     * @author: chenyu.wang
     * @date: 2020-08-24
     */
    Integer queryYesterDaySum(@Param("shopId") Long shopId, @Param("date")String date);

    /*
     * @description:获取店铺昨日商品浏览量
     * @author: chenyu.wang
     * @date: 2020-08-24
     */
    Integer queryYesterDayGoodsNum(@Param("shopId") Long shopId, @Param("date")String date);

    Integer queryYesterDayShopNum(@Param("shopId") Long shopId, @Param("date")String date);

    Integer queryYesterDayGoodsIPNum(@Param("shopId") Long shopId, @Param("date")String date);

    ShopOperationSevenVO queryGoodsPageViewsToday(@Param("item") ShopOperationBO bo);

    ShopOperationSevenVO queryGoodsVisitorsToday(@Param("item") ShopOperationBO bo);

    List<ShopOperationSevenVO> queryGoodsPageViewsThisWeek(@Param("item") ShopOperationBO bo);

    List<ShopOperationSevenVO> queryGoodsVisitorsThisWeek(@Param("item") ShopOperationBO bo);

    List<ShopOperationSevenVO> queryGoodsPageViewsThisMonth(@Param("item") ShopOperationBO bo);

    List<ShopOperationSevenVO> queryGoodsVisitorsThisMonth(@Param("item") ShopOperationBO bo);

    ShopOperationSevenVO queryGoodsPageViewsAutoTime(@Param("item") ShopOperationBO bo);

    ShopOperationSevenVO querygoodsVisitorsAutoTime(@Param("item") ShopOperationBO bo);
}
